import 'package:flutter/material.dart';

class HomePage extends StatelessWidget
{
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(title: Text("MJPEG DEMO")),
      body: Center(
        child: Column(
          mainAxisAlignment: MainAxisAlignment.center,
          children: [
            SizedBox(
              width: 300,
              child: OutlineButton.icon(
                onPressed: () => Navigator.pushNamed(context, 'fromHttpPage'),
                icon: Icon(Icons.cloud_download_rounded, color: Colors.blue),
                label: Text("From HTTP Stream"),
              )
            ),
            SizedBox(
              width: 300,
              child: OutlineButton.icon(
                onPressed: () => Navigator.pushNamed(context, 'fromFilePage'),
                icon: Icon(Icons.filter, color: Colors.green),
                label: Text("From File Stream")
              )
            ),
            SizedBox(
              width: 300,
              child: OutlineButton.icon(
                onPressed: () => Navigator.pushNamed(context, 'fromResourcePage'),
                icon: Icon(Icons.assessment, color: Colors.orange),
                label: Text("From Resource Stream")
              )
            )
          ]
        )
      )
    );
  }
}